From 8123a6fe99e01e93b480f036dfee262139e33ae8 Mon Sep 17 00:00:00 2001
From: Fuwn <contact@fuwn.me>
Date: Sun, 28 Apr 2024 23:43:57 -0700
Subject: feat(badges): allow awc badges hiding

---
 src/routes/user/[user]/+page.svelte | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

(limited to 'src/routes/user/[user]/+page.svelte')

diff --git a/src/routes/user/[user]/+page.svelte b/src/routes/user/[user]/+page.svelte
index 222e044f..7049cbfd 100644
--- a/src/routes/user/[user]/+page.svelte
+++ b/src/routes/user/[user]/+page.svelte
@@ -225,6 +225,20 @@
 
 			<p />
 
+			<input
+				type="checkbox"
+				on:change={() => {
+					if (userData)
+						fetch(root(`/api/preferences?id=${userData.id}&toggleHideAWCBadges`), {
+							method: 'PUT'
+						});
+				}}
+				checked={preferences.hide_awc_badges}
+			/>
+			{$locale().user.preferences.hideAWCBadges.title}
+
+			<p />
+
 			Biography
 
 			<button
-- 
cgit v1.2.3

